#ifndef MAC_WHITELIST_H
#define MAC_WHITELIST_H

#include "common/baseeditor.h"
#include "mac_additem.h"

namespace Ui {
class MacWhiteList;
}

class MacWhiteList : public BaseEditor
{
    Q_OBJECT

public:
    explicit MacWhiteList(QWidget *parent = nullptr);
    ~MacWhiteList();

    void generateMenu();
    void updateView();
    void updateDepartment();
    void setHeaderData();
    void newItem();
    void removeItem();

protected:
    void keyPressEvent(QKeyEvent *event);

private slots:
    void on_listView_doubleClicked(const QModelIndex &index);

    void on_kw_editingFinished();

private:
    Ui::MacWhiteList *ui;

    QString selectDepartment;
    QStringListModel *listModel;
};

#endif // MAC_WHITELIST_H
